<template>
	<div id="app">
		<keep-alive>
			<component :is="layout">
				<router-view />
			</component>
		</keep-alive>
	</div>
</template>

<script>
	import { mapState, mapGetters, mapMutations, mapActions } from "vuex"
	export default {
		computed: {
			// Sets components name based on current route's specified layout, defaults to
			// <layout-default></layout-default> component.
			layout() {
				return "layout-" + (this.$route.meta.layout || "default").toLowerCase()
			}
		},
		created() {
			console.log("Vue Created")
			this.getWebsiteConfigInfo()
		},
		methods: {
			...mapActions("app", ["getWebsiteConfigInfo"])
		}
	}
</script>

<style lang="scss"></style>
